#include "NotifyManager.h"
#include "CommonUtils.h"

NotifyManager* NotifyManager::instance = nullptr;

NotifyManager::NotifyManager()
    :QObject(nullptr)
{
}

NotifyManager::~NotifyManager()
{
}
//单例模式，获取唯一对象
NotifyManager* NotifyManager::getInstance()
{
    if (instance == nullptr)
    {
        instance = new NotifyManager();
    }

    return instance;
}
//通知其他窗口进行改变颜色
void NotifyManager::notifyOtherWindowChangeSkin(const QColor& color)
{
    emit signalSkinChanged(color);
    CommonUtils::setDefaultSkinColor(color);//将配置文件中的颜色进行重写
}
